package com.gxa.jd.interceptor;

import com.gxa.jd.pojo.User;

/**
 * Created by zxd on 2021/1/6
 **/
public class UserThreadLocal {

    private static ThreadLocal<User> tl=new ThreadLocal<>();

    public static void set(User user){
        tl.set(user);
    }

    public static User get(){
        return tl.get();
    }

    public static void remove(){
        tl.remove();
    }

}
